Partial redundancy elimination is a compiler optimization that eliminates expressions that are redundant on some but not necessarily all paths through a program. Presently, many different partial redundancy elimination (PRE) algorithms attempt to solve the issue of redundancy, while taking different priorities into consideration. However, PRE algorithms commonly assume there is an unlimited number of temporary memory locations available that can store a value of an expression for an undefined period of time. Such an assumption of an infinite number of temporary memory location is typical when performing redundancy elimination early in the optimization phase.